package com.joven.shelltest.utils.testfactory;

import java.util.Objects;

/**
 * @Author wzj
 * @Date 2023-09-18 09:16
 **/
public class ApiLimitGatewayHandler extends GatewayHandler {

    private int play() {
        return 80;
    }

    @Override
    public int doSomething() {
        System.out.println("ApiLimit do");
        int score = play();
        if (score >= 80) {
            if (Objects.nonNull(this.next)) {
                this.next.doSomething();
            }

        }
        return score;
    }
}
